Skip to main content
Version: 3.8

Fault Configuration

THAPI Manager allows users to centrally configure fault handling for gateway errors across multiple gateways within an organization. These configurations encompass fault structure, content type (applicable to REST and SOAP) and fault messages, ensuring consistent error handling and customization at global, gateway, plan and resource levels. Each level offers the flexibility to override settings as needed, ensuring precise error responses tailored to API versions, plans and subscriptions.

  1. Navigate to the Global Configuration module's Fault Configuration sub-module.

faultconfig

Configure Rest Fault Configuration

Configure Default Content Type

The Content Type can be overwritten for Resources, Gateway, as well as at the plan level.

  1. Select REST tab.

  2. Click to expand the Default Content Type.

faultconfig1

  1. Click to choose the necessary Content Type (JSON/XML/PlainText) option to be defined at Gateway Level, Plan Level and Resource Level.

  2. Click Save.

On saving, the confirmation message appears as shown below.

faultconfig2

Configure Default Fault Structure

The Fault Structure can be overwritten for Resources, Gateway, as well as at the plan level.

  1. Select REST tab.

  2. Click to expand the Default Content Type.

faultconfig3

  1. Edit the JSON, XML, or Plain Text Fault box to modify the Fault template at the Gateway, Plan and Resource level as needed.

  2. Click Save.

On saving, the confirmation message appears as shown below.

faultconfig4

Update Scenario-wise Fault Message

The Fault Message can be overwritten for Resources, Gateway as well as at the plan level.

  1. Select REST tab.

  2. Click to expand the Scenario-wise Fault Message.

faultconfig5

  1. Edit the Response Code, HTTP Code and Fault Message Content for each Scenario at the Gateway, Plan and for Resource level as needed.

  2. Click Save.

On saving, the confirmation message appears as shown below.

faultconfig6

Configure SOAP Fault Configuration

Configure Default Fault Structure

The Fault Structure can be overwritten for Gateway, Operations, as well as at the plan level.

  1. Select SOAP tab.

  2. Click to expand the Default Fault Structure.

faultconfig7

  1. Edit the XML Fault as needed.

  2. Click Save.

On saving, the confirmation message appears as shown below.

faultconfig8

Configure Scenario-wise Fault Message

The Fault Message can be overwritten for Gateway, Operations, as well as at the plan level.

  1. Select SOAP tab.

  2. Click to expand the Scenario-wise Fault Message.

faultconfig9

  1. Edit the Response Code, HTTP Code and Fault Message Content for each Scenario at the Gateway, Plan Level and for operations level as needed.

  2. Click Save.

On saving, the confirmation message appears as shown below.

faultconfig10

Configure GraphQL Fault Configuration

Configure Default Fault Structure

The Fault Structure can be overwritten for Gateway, Resources, as well as at the plan level.

  1. Select GraphQL tab.

  2. Click to expand the Default Fault Structure.

faultconfig11

  1. Edit the JSON Fault at the Gateway, Plan Level and for Resource level as needed.

  2. Click Save.

On saving, the confirmation message appears as shown below.

faultconfig12

Configure Scenario-wise Fault Message

The Fault Message can be overwritten for Gateway, Resources, as well as at the plan level.

  1. Select GraphQL tab.

  2. Click to expand the Scenario-wise Fault Message.

faultconfig13

  1. Edit the Response Code, HTTP Code and Fault Message Content for each Scenario at the Plan level, Gateway level and for Resource level as needed.

  2. Click Save.

On saving, the confirmation message appears as shown below.

faultconfig14